<?php
include 'config/config.php';
include 'lib/promo.php';
include 'lib/member.php';
include 'lib/produk.php';
include 'lib/tipe.php';

$config=new config();
$config->connect();

if (ISSET($_GET["id"])){
$id=$_GET["id"];
//echo $id;
$Produk_Dao=new Produk_Dao();
$produk=$Produk_Dao->get_id($id);
//echo $produk->id_produk;

$Tipe_Dao=new Tipe_Dao();
$tipe=$Tipe_Dao->get_id($produk->id_tipe);

$Member_Dao=new Member_Dao();
$member=$Member_Dao->get_id($produk->id);

}


?>
<?php include("header.php") ?>
<?php include("menu_kiri.php") ?>

<div id="body">
<div class="topbox2">
                  Detil Produk:
                  <br>
				  <br>
				  <?php echo "<image src=\"member/images/produk/$produk->foto_produk\" width=\"300\" height=\"200\" class=\"left\">"; ?>
				  <br />
				  
                  <table class="table" cellspacing=0 cellpadding=3>
				  <tr>
					<td >Nama Kamar</td>
					<td>:</td>
					<td ><?php echo $produk->nama_produk; ?></td>				
				  </tr>
				  
				  <tr>
					<td>Tipe Bed</td>
					<td>:</td>
					<td><?php echo $tipe->tipe;?></td>				
				  </tr>
				  
				  <tr>
					<td>Fasilitas</td>
					<td>:</td>
					<td><?php echo $produk->fasilitas; ?></td>				
				  </tr>
				  
				  <tr>
					<td>Harga normal</td>
					<td>:</td>
					<td><?php echo "Rp".number_format($produk->harga, 2, '.', ','); ?></td>				
				  </tr>
				  
				  <tr>
					<td>Nama Penyedia</td>
					<td>:</td>
					<td><?php echo "<a href=\"detil_hotel.php?id=$produk->id\">".ucwords($member->nama)."</a>"; ?></td>				
				  </tr>
				  
				  </table>
				  <br/>
				  <INPUT TYPE="button" VALUE="Back" onClick="history.go(-1);">
                  
                  
	                  
</div>             
</div>
          
         <div class="clear"></div>
         <?php include("footer.php") ?>
		